package com.ruoyi.web.controller.wq;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import com.ruoyi.common.core.controller.BaseController;
import com.ruoyi.common.core.domain.AjaxResult;
import com.ruoyi.common.core.page.TableDataInfo;
import com.ruoyi.wq.domain.WqUserVisit;
import com.ruoyi.wq.domain.vo.WqUserVisitVO;
import com.ruoyi.wq.service.IWqUserVisitService;

/**
 * 用户访客记录Controller
 * 
 * @author ruoyi
 * @date 2022-09-26
 */
@RestController
@RequestMapping("/wq/userVisit")
public class WqUserVisitController extends BaseController {
	
    @Autowired
    private IWqUserVisitService wqUserVisitService;

    @GetMapping("/getList")
    public TableDataInfo getList(WqUserVisitVO wqUserVisit){
    	TableDataInfo list = wqUserVisitService.getList(wqUserVisit);
        return list;
    }

    /**
     * 新增用户访客记录
     */
    @PostMapping
    public AjaxResult add(@RequestBody WqUserVisit wqUserVisit){
        return toAjax(wqUserVisitService.insertWqUserVisit(wqUserVisit));
    }
    
}
